package com.jingbian.cppccbackend.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import jakarta.validation.constraints.NotNull;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;
import lombok.AllArgsConstructor;

import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * <p>
 * 提案信息表
 * </p>
 *
 * @author yezi
 * @since 2025-02-11
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
@EqualsAndHashCode(callSuper = false)
public class Proposals implements Serializable {

    private static final long serialVersionUID = 1L;

    @NotNull
    @TableId(value = "pid", type = IdType.AUTO)
    private Integer pid; // 提案ID

    @TableField("user_id")
    private Integer userId; // 用户ID(外键)

    private String proposer; // 提案人

    @TableField(exist = false)
    private String phone; // 提案人电话

    @TableField(exist = false)
    private String affiliation; // 提案人所属单位

    private String address;
    private  String postalCode;

    @TableField("case_reason")
    private String caseReason; // 案由

    @TableField("proposal_content")
    private String proposalContent; // 提案内容

    @TableField("proposer_region")
    private String proposerRegion; // 提案人地区

    @TableField("proposal_type")
    private String proposalType; // 提案类型

    @TableField("is_public")
    private Boolean isPublic; // 是否愿意被公开

    private Boolean finalPublic; // 最终批复是否公开

    @TableField("final_disposition")
    private String finalDisposition; // 处理结果

    @TableField("status")
    private String status; // 状态

    @TableField("submit_time")
    private LocalDateTime submitTime; // 提案时间

    @TableField("first_audit_time")
    private LocalDateTime firstAuditTime; // 初审时间

    @TableField("recheck_time")
    private LocalDateTime recheckTime; // 复审时间

    @TableField("shunt_time")
    private LocalDateTime shuntTime; // 分流时间

    @TableField("special_handling_time")
    private LocalDateTime specialHandlingTime; // 专项处理时间

    @TableField("final_reply_time")
    private LocalDateTime finalReplyTime; // 最终批复时间

    @TableField("completion_time")
    private LocalDateTime completionTime; // 处理完结时间

    @TableField("is_frist")
    private Boolean isFrist; // 初审是否通过

    @TableField("is_recheck")
    private Boolean isRecheck; // 复审是否通过

    @TableField("is_shunt")
    private Boolean isShunt; // 是否分流

    @TableField("department")
    private String department; // 分流部门

    @TableField("is_handing")
    private Boolean isHanding; // 专项处理是否通过

    @TableField("handing_result")
    private String handingResult; // 专项处理结果

    @TableField("is_final")
    private Integer isFinal; // 最终批复是否通过

    @TableField(exist = false)
    private String attachments; // 提案附件（逗号分隔的字符串）

    @TableField(exist = false)
    private String signers; // 提案联名人（逗号分隔的字符串）

    @TableField(exist = false)
    private String handlingAttachments;  // 专项处理附件

    private Boolean isOr;

    private LocalDateTime isOrTime;//进入初审的时间

    private String topic;

    private String organizerWill;

    private Boolean isCancel;


}

